using System;
using System.Collections;
using System.Collections.Generic;

using NHibernate.Data.Base;

namespace NHibernate.Data.Models
{
    public partial class ReWineAward : BusinessBase<string>
    {
        #region Declarations

		private long _wine = default(Int64);
		private long _award = default(Int64);
		
		private long _introduction = default(Int64);
		private string _vintage = String.Empty;
		private string _awardYear = String.Empty;
		
		
		
        #endregion

        #region Constructors

        public ReWineAward() { }

        #endregion

        #region Methods

        public override int GetHashCode()
        {
            System.Text.StringBuilder sb = new System.Text.StringBuilder();
            
            sb.Append(this.GetType().FullName);
			sb.Append(_introduction);
			sb.Append(_vintage);
			sb.Append(_awardYear);

            return sb.ToString().GetHashCode();
        }

        #endregion

        #region Properties

		public override string Id
		{
			get
			{
				System.Text.StringBuilder uniqueId = new System.Text.StringBuilder();
				uniqueId.Append(_wine.ToString());
				uniqueId.Append("^");
				uniqueId.Append(_award.ToString());
				return uniqueId.ToString();
			}
		}
		
		public virtual long Wine
        {
            get { return _wine; }
			set
			{
				
				OnWineChanging();
				_wine = value;
				OnWineChanged();
			}
        }
		partial void OnWineChanging();
		partial void OnWineChanged();
		
		public virtual long Award
        {
            get { return _award; }
			set
			{
				
				OnAwardChanging();
				_award = value;
				OnAwardChanged();
			}
        }
		partial void OnAwardChanging();
		partial void OnAwardChanged();
		
		public virtual long Introduction
        {
            get { return _introduction; }
			set
			{
				OnIntroductionChanging();
				_introduction = value;
				OnIntroductionChanged();
			}
        }
		partial void OnIntroductionChanging();
		partial void OnIntroductionChanged();
		
		public virtual string Vintage
        {
            get { return _vintage; }
			set
			{
				OnVintageChanging();
				_vintage = value;
				OnVintageChanged();
			}
        }
		partial void OnVintageChanging();
		partial void OnVintageChanged();
		
		public virtual string AwardYear
        {
            get { return _awardYear; }
			set
			{
				OnAwardYearChanging();
				_awardYear = value;
				OnAwardYearChanged();
			}
        }
		partial void OnAwardYearChanging();
		partial void OnAwardYearChanged();
		
        #endregion
    }
}
